<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <div id="app">
        <div>
            <router-link to="/hello">hello</router-link>
            <!-- <a href="#hello">hello</a></a> -->
        </div>
       
        <div>
            <router-view></router-view>
        </div>
       
    </div>
    <template>
        <div></div>
    </template>
    <script src="./node_modules/vue/dist/vue.js"></script>
    <script src="./node_modules/vue-router/dist/vue-router.js"></script>
    <script>
        const hello = {
            template:"<div>{{name}}<div>",
            data() {
                return {
                    name: '帅',
                };
            },
        }

        const router = new VueRouter({
            routes:[
                { path: '/hello', component: hello },
            ]
        });

        new Vue({
            el:"#app",
            router
        })
    </script>
</body>
</html>